package com.ruoyi.recycle.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.recycle.domain.PlatformInformManagement;
import com.ruoyi.recycle.mapper.PlatformInformManagementMapper;
import com.ruoyi.recycle.service.IPlatformInformManagementService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 平台通知管理Service业务层处理
 *
 * @author Wubk
 * @date 2022-05-22
 */
@Service
public class PlatformInformManagementServiceImpl extends ServiceImpl<PlatformInformManagementMapper, PlatformInformManagement> implements IPlatformInformManagementService {
    @Autowired
    private PlatformInformManagementMapper platformInformManagementMapper;

    /**
     * 查询平台通知管理
     *
     * @param id 平台通知管理主键
     * @return 平台通知管理
     */
    @Override
    public PlatformInformManagement selectPlatformInformManagementById(Long id) {
        return platformInformManagementMapper.selectPlatformInformManagementById(id);
    }

    /**
     * 查询平台通知管理列表
     *
     * @param platformInformManagement 平台通知管理
     * @return 平台通知管理
     */
    @Override
    public List<PlatformInformManagement> selectPlatformInformManagementList(PlatformInformManagement platformInformManagement) {
        return platformInformManagementMapper.selectPlatformInformManagementList(platformInformManagement);
    }

    /**
     * 新增平台通知管理
     *
     * @param platformInformManagement 平台通知管理
     * @return 结果
     */
    @Override
    public int insertPlatformInformManagement(PlatformInformManagement platformInformManagement) {
        return save(platformInformManagement) ? 1 : 0;
    }

    /**
     * 修改平台通知管理
     *
     * @param platformInformManagement 平台通知管理
     * @return 结果
     */
    @Override
    public int updatePlatformInformManagement(PlatformInformManagement platformInformManagement) {
        return platformInformManagementMapper.updatePlatformInformManagement(platformInformManagement);
    }

    /**
     * 批量删除平台通知管理
     *
     * @param ids 需要删除的平台通知管理主键
     * @return 结果
     */
    @Override
    public int deletePlatformInformManagementByIds(Long[] ids) {
        return platformInformManagementMapper.deletePlatformInformManagementByIds(ids);
    }

    /**
     * 删除平台通知管理信息
     *
     * @param id 平台通知管理主键
     * @return 结果
     */
    @Override
    public int deletePlatformInformManagementById(Long id) {
        return platformInformManagementMapper.deletePlatformInformManagementById(id);
    }
}
